<template>
    <div>
        <ul>
            <li><a href="https://blog.csdn.net/zfw_666666/article/details/126287239"
                    target="_blank">几个免费的富文本编辑器，这不完胜付费？</a></li>
            <li><a href="https://zhuanlan.zhihu.com/p/435275506" target="_blank">免费JS富文本编辑器 总有一款会适合你!</a></li>
        </ul>
        <editor-input v-model:value="dataOfForm.content" />
        <el-button @click="onSubmit">提交</el-button>
    </div>
</template>
  
<script setup>
import EditorInput from '@/components/editor/EditorTinymce.vue'
import { ref, onMounted } from 'vue';

const dataOfForm = ref({ content: '' });

const onSubmit = () => {
    console.log(JSON.stringify(dataOfForm.value));
}
const loadData = () => {
    setTimeout(() => {
        dataOfForm.value.content = '<p>hello</p><a href="#">link</a>';
    }, 1000)
}

onMounted(() => {
    loadData();
})
</script>